// ********************************
// dialog.js Script
// ********************************

var SplashFont = "system.rfn";
//var SplashFont = "beakerbigmain.rfn";
//var SplashFont = "base.rfn";

// Pops up a "Toad" info window
function ToadSplash(StringArray){
//  setWindowBehavior(SplashFont, "toad.rws");
  setWindowBehavior(SplashFont, "toad.rws",1);
  setColours(CreateColor(0,0,0,100), CreateColor(0,0,0,100), CreateColor(0,0,0,100), CreateColor(0,0,0,100), CreateColor(255,255,255,255));
  drawCenter(StringArray, 25, "ScrollUp");
}

// Pops up a "Cloud" info window
function CloudSplash(StringArray){
//  setWindowBehavior(SplashFont, "cloud.rws");
  setWindowBehavior(SplashFont, "cloud.rws",1);
  setColours(CreateColor(0,0,0,100), CreateColor(0,0,0,100), CreateColor(0,0,0,100), CreateColor(0,0,0,100), CreateColor(255,255,255,255));
  drawCenter(StringArray, 25, "ScrollUp");
}

// Pops up a "Death" info window
function DeathSplash(StringArray){
//  setWindowBehavior(SplashFont, "cloud.rws");
  setWindowBehavior(SplashFont, "death.rws",1);
  setColours(CreateColor(0,0,0,100), CreateColor(0,0,0,100), CreateColor(0,0,0,100), CreateColor(0,0,0,100), CreateColor(255,255,255,255));
  drawCenter(StringArray, 25, "ScrollUp");
}

// Fades an image in, waits for a keypress, and fades out
function IntroImage(name)
{
  var image = LoadImage(name);
  image.blit(0, 0);
  FadeIn(1200);
  GetKey();
  FadeOut(1200);
  ClearScreen();  
  FlipScreen();
}
